// 用户模块

// 引入本地储存
import { setTken, getToken } from '@/utils/storage'

const state = {
  tokenInfo: getToken()
}

const mutations = {
  setTokenInfo(state, newTokenInfo) {
    state.tokenInfo = newTokenInfo
    setTken(newTokenInfo)
  }
}

const getters = {}
const actions = {}

export default {
  namespaced: true,
  state,
  mutations,
  getters,
  actions
}
